<template>
  <div>
    <el-input v-model="data" type="textarea" @input="change" :autosize="{ minRows: 4}"></el-input>
  </div>
</template>

<script>
  export default {
    name: "InputDescription",
    model: {
      prop: 'value',
      event: 'change'
    },
    props: {
      value: {
        type: String,
        default: ''
      }
    },
    watch: {
      value: {
        handler(val) {
          this.data = val
        }
      }
    },
    data() {
      return {
        data: ''
      }
    },
    methods: {
      change(val) {
        this.$emit('change', val)
      }
    }
  }
</script>

<style scoped>

</style>
